# encoding：utf-8
# @File   : read_file.py
# @Author : 乖孩子
# @Date   : 2025-05-12 13-36-15
from openpyxl import load_workbook

from config.config import DELETE_SUBSYSTEM_FILE_PATH


def read_deleteSubSystem_xlsx_data(file_path):
    workbook = load_workbook(file_path)
    sheet = workbook.active
    testdata = []
    for row in sheet.iter_rows(min_row=2, values_only=True):  # 从第二行开始，跳过表头
        # 将元组中的元素转换为字符串，并用逗号连接
        row_as_string = ', '.join(map(str, row))
        testdata.append(row_as_string)

    return testdata

# 调用函数并打印结果
print(read_deleteSubSystem_xlsx_data(DELETE_SUBSYSTEM_FILE_PATH))
